<%@ page import="com.okaysoft.ofb.Terminal" %>

<div id="show_details" style="padding: 5px 0 0 0;background: #E0ECFF">
    <div id="show_details_tab" class="easyui-tabs" fit="true" border="false">
        <div title="概要信息" style="padding:20px;" icon="icon-base">
            <div id="show_details_tab_gy" class="select-composition"></div>
        </div>
        <div title="端子信息" style="padding:10px;" icon="icon-ports">
            <div class="easyui-layout" style="height:330px;">

                <div region="west" style="width:100px;border-right-width: 0;">
                    <ul id="show_details_terminal_tree" class="easyui-tree" animate="true">

                    </ul>
                </div>
                <div region="center">
                    <div id="show_details_terminal_formwork" style="height: 300px;padding:5px;">

                    </div>
                    <div id="show_details_terminal_content" style="height: 300px;padding:5px;"></div>
                </div>
                <div region="east" style="width:200px;border-left-width: 0;padding: 2px" id="terminal_detail_container">
                       <span>loading...</span>
                </div>
            </div>
        </div>
        <div title="地理位置" style="padding:20px;" icon="icon-map">
            <div id="device_map" style="width: 100%;height: 100%;border: 1px solid #cccccc">loading...</div>
        </div>
        <div title="任务管理" style="padding:5px;" icon="icon-task">
            <div id="show_task_details_tab" class="easyui-tabs" fit="true">
                <div title="未完成" style="padding:10px;">
                    <table id="task_uncomplete"></table>
                </div>
                <div title="已完成" style="padding:10px;">
                    <table id="task_complete"></table>
                </div>
            </div>
        </div>
    </div>
</div>

<div id="task_dg" style="padding:5px 10px">
    <g:form name="add_task_form" action="save" controller="task" class="add_task_form">
        <g:render template="/task/form"/>
    </g:form>
</div>

<div id="terminal_clientuser_dg" style="padding:5px 10px">
    <table id="terminal_clientuser_tb" class="easyui-datagrid" style="width:600px;height:250px" toolbar="#terminal_clientuser_tb_toolbar"></table>
</div>
<div id="terminal_clientuser_tb_toolbar" style="padding:5px;height:auto">
    <a href="javascript:void 0" class="easyui-linkbutton terminal_clientuser_tb_save" iconCls="icon-save" plain="true">保存</a>
    <a href="javascript:void 0" class="easyui-linkbutton terminal_clientuser_tb_del" iconCls="icon-remove" plain="true">删除</a>
    <div>
        选择用户： <select id="client_combo" style="width:200px;" url="${createLink(uri: '/client/treeJson1')}"></select>
    </div>
</div>

<div id="device_route_dg" style="padding:5px 10px">
    <iframe scrolling="auto" id='device_route_ifr' frameborder="0"  src="" style="width:100%;height:100%;"></iframe>
</div>

<g:hiddenField name="deviceUrl" value="${createLink(uri: '/device/show')}"/>
<g:hiddenField name="terminalUrl" value="${createLink(uri: '/device/terminal')}"/>
<g:hiddenField name="compositionUrl" value="${createLink(uri: '/formwork/getComposition')}"/>
<g:hiddenField name="formworkUrl" value="${createLink(uri: '/formwork/showJson')}"/>
<g:hiddenField name="saveDeviceFormworkUrl" value="${createLink(uri: '/device/saveDeviceFormwork')}"/>
<g:hiddenField name="taskStatusUrl" value="${createLink(uri: '/task/complete')}"/>
<g:hiddenField name="getTerminalUrl" value="${createLink(uri: '/device/getTerminal')}"/>
<g:hiddenField name="terminalObjUrl" value="${createLink(uri: '/device/terminalObj')}"/>
<g:hiddenField name="taskDeleteUrl" value="${createLink(uri: '/task/delete')}"/>
<g:hiddenField name="getClientUrl" value="${createLink(uri: '/client/getClientUserForJson')}"/>
<g:hiddenField name="routeUrl" value="${createLink(uri: '/device/route')}"/>
<g:hiddenField name="terminalClientUserUrl" value="${createLink(uri: '/device/cu')}"/>
<g:hiddenField name="saveTerminalClientUserUrl" value="${createLink(uri: '/device/saveClientUser')}"/>
<g:hiddenField name="deleteTerminalClientUserUrl" value="${createLink(uri: '/device/removeTcu')}"/>
